package chapter15;

/**
 * @author : DuJiabao
 * @Date : 2021/3/4 15:41
 * @Project : thinking_in_java
 * @File : null.java
 * @Desc :
 */
public class Tuple {
  public static <A, B> TwoTuple<A, B> tuple(A a, B b) {
    return new TwoTuple<>(a, b);
  }

  public static <A, B, C> ThreeTuple<A, B, C> tuple(A a, B b, C c) {
    return new ThreeTuple<>(a, b, c);
  }

  public static void main(String[] args) {
    ThreeTuple<Integer, Integer, Integer> tuple = tuple(1, 2, 3);
    System.out.println(tuple);
  }
}
